Termination w.r.t. Q of the following Term Rewriting System could be proven:

Q restricted rewrite system:
The TRS R consists of the following rules:

a(f, 0) → a(s, 0)
a(d, 0) → 0
a(d, a(s, x)) → a(s, a(s, a(d, a(p, a(s, x)))))
a(f, a(s, x)) → a(d, a(f, a(p, a(s, x))))
a(p, a(s, x)) → x

Q is empty.


QTRS
  ↳ RRRPoloQTRSProof

Q restricted rewrite system:
The TRS R consists of the following rules:

a(f, 0) → a(s, 0)
a(d, 0) → 0
a(d, a(s, x)) → a(s, a(s, a(d, a(p, a(s, x)))))
a(f, a(s, x)) → a(d, a(f, a(p, a(s, x))))
a(p, a(s, x)) → x

Q is empty.

The following Q TRS is given: Q restricted rewrite system:
The TRS R consists of the following rules:

a(f, 0) → a(s, 0)
a(d, 0) → 0
a(d, a(s, x)) → a(s, a(s, a(d, a(p, a(s, x)))))
a(f, a(s, x)) → a(d, a(f, a(p, a(s, x))))
a(p, a(s, x)) → x

Q is empty.
The following rules can be removed by the rule removal processor [15] because they are oriented strictly by a polynomial ordering:

a(f, 0) → a(s, 0)
Used ordering:
Polynomial interpretation [25]:

POL(0) = 0   
POL(a(x1, x2)) = x1 + x2   
POL(d) = 0   
POL(f) = 1   
POL(p) = 0   
POL(s) = 0   




↳ QTRS
  ↳ RRRPoloQTRSProof
QTRS
      ↳ Overlay + Local Confluence

Q restricted rewrite system:
The TRS R consists of the following rules:

a(d, 0) → 0
a(d, a(s, x)) → a(s, a(s, a(d, a(p, a(s, x)))))
a(f, a(s, x)) → a(d, a(f, a(p, a(s, x))))
a(p, a(s, x)) → x

Q is empty.

The TRS is overlay and locally confluent. By [19] we can switch to innermost.

↳ QTRS
  ↳ RRRPoloQTRSProof
    ↳ QTRS
      ↳ Overlay + Local Confluence
QTRS
          ↳ DependencyPairsProof

Q restricted rewrite system:
The TRS R consists of the following rules:

a(d, 0) → 0
a(d, a(s, x)) → a(s, a(s, a(d, a(p, a(s, x)))))
a(f, a(s, x)) → a(d, a(f, a(p, a(s, x))))
a(p, a(s, x)) → x

The set Q consists of the following terms:

a(d, 0)
a(d, a(s, x0))
a(f, a(s, x0))
a(p, a(s, x0))


Using Dependency Pairs [1,15] we result in the following initial DP problem:
Q DP problem:
The TRS P consists of the following rules:

A(d, a(s, x)) → A(p, a(s, x))
A(f, a(s, x)) → A(d, a(f, a(p, a(s, x))))
A(d, a(s, x)) → A(s, a(d, a(p, a(s, x))))
A(f, a(s, x)) → A(p, a(s, x))
A(f, a(s, x)) → A(f, a(p, a(s, x)))
A(d, a(s, x)) → A(d, a(p, a(s, x)))
A(d, a(s, x)) → A(s, a(s, a(d, a(p, a(s, x)))))

The TRS R consists of the following rules:

a(d, 0) → 0
a(d, a(s, x)) → a(s, a(s, a(d, a(p, a(s, x)))))
a(f, a(s, x)) → a(d, a(f, a(p, a(s, x))))
a(p, a(s, x)) → x

The set Q consists of the following terms:

a(d, 0)
a(d, a(s, x0))
a(f, a(s, x0))
a(p, a(s, x0))

We have to consider all minimal (P,Q,R)-chains.

↳ QTRS
  ↳ RRRPoloQTRSProof
    ↳ QTRS
      ↳ Overlay + Local Confluence
        ↳ QTRS
          ↳ DependencyPairsProof
QDP
              ↳ DependencyGraphProof

Q DP problem:
The TRS P consists of the following rules:

A(d, a(s, x)) → A(p, a(s, x))
A(f, a(s, x)) → A(d, a(f, a(p, a(s, x))))
A(d, a(s, x)) → A(s, a(d, a(p, a(s, x))))
A(f, a(s, x)) → A(p, a(s, x))
A(f, a(s, x)) → A(f, a(p, a(s, x)))
A(d, a(s, x)) → A(d, a(p, a(s, x)))
A(d, a(s, x)) → A(s, a(s, a(d, a(p, a(s, x)))))

The TRS R consists of the following rules:

a(d, 0) → 0
a(d, a(s, x)) → a(s, a(s, a(d, a(p, a(s, x)))))
a(f, a(s, x)) → a(d, a(f, a(p, a(s, x))))
a(p, a(s, x)) → x

The set Q consists of the following terms:

a(d, 0)
a(d, a(s, x0))
a(f, a(s, x0))
a(p, a(s, x0))

We have to consider all minimal (P,Q,R)-chains.
The approximation of the Dependency Graph [15,17,22] contains 2 SCCs with 5 less nodes.

↳ QTRS
  ↳ RRRPoloQTRSProof
    ↳ QTRS
      ↳ Overlay + Local Confluence
        ↳ QTRS
          ↳ DependencyPairsProof
            ↳ QDP
              ↳ DependencyGraphProof
                ↳ AND
QDP
                    ↳ UsableRulesProof
                  ↳ QDP

Q DP problem:
The TRS P consists of the following rules:

A(d, a(s, x)) → A(d, a(p, a(s, x)))

The TRS R consists of the following rules:

a(d, 0) → 0
a(d, a(s, x)) → a(s, a(s, a(d, a(p, a(s, x)))))
a(f, a(s, x)) → a(d, a(f, a(p, a(s, x))))
a(p, a(s, x)) → x

The set Q consists of the following terms:

a(d, 0)
a(d, a(s, x0))
a(f, a(s, x0))
a(p, a(s, x0))

We have to consider all minimal (P,Q,R)-chains.
As all Q-normal forms are R-normal forms we are in the innermost case. Hence, by the usable rules processor [15] we can delete all non-usable rules [17] from R.

↳ QTRS
  ↳ RRRPoloQTRSProof
    ↳ QTRS
      ↳ Overlay + Local Confluence
        ↳ QTRS
          ↳ DependencyPairsProof
            ↳ QDP
              ↳ DependencyGraphProof
                ↳ AND
                  ↳ QDP
                    ↳ UsableRulesProof
QDP
                        ↳ ATransformationProof
                  ↳ QDP

Q DP problem:
The TRS P consists of the following rules:

A(d, a(s, x)) → A(d, a(p, a(s, x)))

The TRS R consists of the following rules:

a(p, a(s, x)) → x

The set Q consists of the following terms:

a(d, 0)
a(d, a(s, x0))
a(f, a(s, x0))
a(p, a(s, x0))

We have to consider all minimal (P,Q,R)-chains.
We have applied the A-Transformation [17] to get from an applicative problem to a standard problem.

↳ QTRS
  ↳ RRRPoloQTRSProof
    ↳ QTRS
      ↳ Overlay + Local Confluence
        ↳ QTRS
          ↳ DependencyPairsProof
            ↳ QDP
              ↳ DependencyGraphProof
                ↳ AND
                  ↳ QDP
                    ↳ UsableRulesProof
                      ↳ QDP
                        ↳ ATransformationProof
QDP
                            ↳ QReductionProof
                  ↳ QDP

Q DP problem:
The TRS P consists of the following rules:

d1(s(x)) → d1(p(s(x)))

The TRS R consists of the following rules:

p(s(x)) → x

The set Q consists of the following terms:

d(0)
d(s(x0))
f(s(x0))
p(s(x0))

We have to consider all minimal (P,Q,R)-chains.
We deleted the following terms from Q as each root-symbol of these terms does neither occur in P nor in R.

d(0)
d(s(x0))
f(s(x0))



↳ QTRS
  ↳ RRRPoloQTRSProof
    ↳ QTRS
      ↳ Overlay + Local Confluence
        ↳ QTRS
          ↳ DependencyPairsProof
            ↳ QDP
              ↳ DependencyGraphProof
                ↳ AND
                  ↳ QDP
                    ↳ UsableRulesProof
                      ↳ QDP
                        ↳ ATransformationProof
                          ↳ QDP
                            ↳ QReductionProof
QDP
                                ↳ RuleRemovalProof
                  ↳ QDP

Q DP problem:
The TRS P consists of the following rules:

d1(s(x)) → d1(p(s(x)))

The TRS R consists of the following rules:

p(s(x)) → x

The set Q consists of the following terms:

p(s(x0))

We have to consider all minimal (P,Q,R)-chains.
By using the rule removal processor [15] with the following polynomial ordering [25], at least one Dependency Pair or term rewrite system rule of this QDP problem can be strictly oriented.

Strictly oriented rules of the TRS R:

p(s(x)) → x

Used ordering: POLO with Polynomial interpretation [25]:

POL(d1(x1)) = x1   
POL(p(x1)) = x1   
POL(s(x1)) = 1 + x1   



↳ QTRS
  ↳ RRRPoloQTRSProof
    ↳ QTRS
      ↳ Overlay + Local Confluence
        ↳ QTRS
          ↳ DependencyPairsProof
            ↳ QDP
              ↳ DependencyGraphProof
                ↳ AND
                  ↳ QDP
                    ↳ UsableRulesProof
                      ↳ QDP
                        ↳ ATransformationProof
                          ↳ QDP
                            ↳ QReductionProof
                              ↳ QDP
                                ↳ RuleRemovalProof
QDP
                                    ↳ DependencyGraphProof
                  ↳ QDP

Q DP problem:
The TRS P consists of the following rules:

d1(s(x)) → d1(p(s(x)))

R is empty.
The set Q consists of the following terms:

p(s(x0))

We have to consider all minimal (P,Q,R)-chains.
The approximation of the Dependency Graph [15,17,22] contains 0 SCCs with 1 less node.

↳ QTRS
  ↳ RRRPoloQTRSProof
    ↳ QTRS
      ↳ Overlay + Local Confluence
        ↳ QTRS
          ↳ DependencyPairsProof
            ↳ QDP
              ↳ DependencyGraphProof
                ↳ AND
                  ↳ QDP
QDP
                    ↳ UsableRulesProof

Q DP problem:
The TRS P consists of the following rules:

A(f, a(s, x)) → A(f, a(p, a(s, x)))

The TRS R consists of the following rules:

a(d, 0) → 0
a(d, a(s, x)) → a(s, a(s, a(d, a(p, a(s, x)))))
a(f, a(s, x)) → a(d, a(f, a(p, a(s, x))))
a(p, a(s, x)) → x

The set Q consists of the following terms:

a(d, 0)
a(d, a(s, x0))
a(f, a(s, x0))
a(p, a(s, x0))

We have to consider all minimal (P,Q,R)-chains.
As all Q-normal forms are R-normal forms we are in the innermost case. Hence, by the usable rules processor [15] we can delete all non-usable rules [17] from R.

↳ QTRS
  ↳ RRRPoloQTRSProof
    ↳ QTRS
      ↳ Overlay + Local Confluence
        ↳ QTRS
          ↳ DependencyPairsProof
            ↳ QDP
              ↳ DependencyGraphProof
                ↳ AND
                  ↳ QDP
                  ↳ QDP
                    ↳ UsableRulesProof
QDP
                        ↳ ATransformationProof

Q DP problem:
The TRS P consists of the following rules:

A(f, a(s, x)) → A(f, a(p, a(s, x)))

The TRS R consists of the following rules:

a(p, a(s, x)) → x

The set Q consists of the following terms:

a(d, 0)
a(d, a(s, x0))
a(f, a(s, x0))
a(p, a(s, x0))

We have to consider all minimal (P,Q,R)-chains.
We have applied the A-Transformation [17] to get from an applicative problem to a standard problem.

↳ QTRS
  ↳ RRRPoloQTRSProof
    ↳ QTRS
      ↳ Overlay + Local Confluence
        ↳ QTRS
          ↳ DependencyPairsProof
            ↳ QDP
              ↳ DependencyGraphProof
                ↳ AND
                  ↳ QDP
                  ↳ QDP
                    ↳ UsableRulesProof
                      ↳ QDP
                        ↳ ATransformationProof
QDP
                            ↳ QReductionProof

Q DP problem:
The TRS P consists of the following rules:

f1(s(x)) → f1(p(s(x)))

The TRS R consists of the following rules:

p(s(x)) → x

The set Q consists of the following terms:

d(0)
d(s(x0))
f(s(x0))
p(s(x0))

We have to consider all minimal (P,Q,R)-chains.
We deleted the following terms from Q as each root-symbol of these terms does neither occur in P nor in R.

d(0)
d(s(x0))
f(s(x0))



↳ QTRS
  ↳ RRRPoloQTRSProof
    ↳ QTRS
      ↳ Overlay + Local Confluence
        ↳ QTRS
          ↳ DependencyPairsProof
            ↳ QDP
              ↳ DependencyGraphProof
                ↳ AND
                  ↳ QDP
                  ↳ QDP
                    ↳ UsableRulesProof
                      ↳ QDP
                        ↳ ATransformationProof
                          ↳ QDP
                            ↳ QReductionProof
QDP
                                ↳ RuleRemovalProof

Q DP problem:
The TRS P consists of the following rules:

f1(s(x)) → f1(p(s(x)))

The TRS R consists of the following rules:

p(s(x)) → x

The set Q consists of the following terms:

p(s(x0))

We have to consider all minimal (P,Q,R)-chains.
By using the rule removal processor [15] with the following polynomial ordering [25], at least one Dependency Pair or term rewrite system rule of this QDP problem can be strictly oriented.

Strictly oriented rules of the TRS R:

p(s(x)) → x

Used ordering: POLO with Polynomial interpretation [25]:

POL(f1(x1)) = x1   
POL(p(x1)) = x1   
POL(s(x1)) = 1 + x1   



↳ QTRS
  ↳ RRRPoloQTRSProof
    ↳ QTRS
      ↳ Overlay + Local Confluence
        ↳ QTRS
          ↳ DependencyPairsProof
            ↳ QDP
              ↳ DependencyGraphProof
                ↳ AND
                  ↳ QDP
                  ↳ QDP
                    ↳ UsableRulesProof
                      ↳ QDP
                        ↳ ATransformationProof
                          ↳ QDP
                            ↳ QReductionProof
                              ↳ QDP
                                ↳ RuleRemovalProof
QDP
                                    ↳ DependencyGraphProof

Q DP problem:
The TRS P consists of the following rules:

f1(s(x)) → f1(p(s(x)))

R is empty.
The set Q consists of the following terms:

p(s(x0))

We have to consider all minimal (P,Q,R)-chains.
The approximation of the Dependency Graph [15,17,22] contains 0 SCCs with 1 less node.